<script setup lang="ts">
import { onMounted, reactive } from 'vue';
const props: any = defineProps<{
    ujt: any;
}>();

const { $global, $fn } = props.ujt;
const kudududata: any = reactive({
    hash: 'robot/indexslam',
});

onMounted(() => {
    // 搜索功能
    document.getElementById('kdd-searchInput').addEventListener('keypress', (e) => {
        if (e.key === 'Enter') {
            const keyword = e.target.value.trim();
            if (keyword) {
                alert(`执行搜索：${keyword}`);
                // 实际搜索逻辑
            }
        }
    });

})
</script>

<template>
    <section class="kdd-hero">
        <div class="kdd-search-box">
            <input type="text" id="kdd-searchInput" placeholder="搜索产品、供应商、求职信息...">
        </div>
    </section>

    <div class="kdd-grid-container">
        <div class="kdd-card" onclick="location.href='#news'">
            <h3>📰 行业资讯</h3>
            <p>最新行业动态与技术发展</p>
        </div>
        <div class="kdd-card" onclick="location.href='#products'">
            <h3>📦 产品库</h3>
            <p>海量机器人产品数据库</p>
        </div>
        <div class="kdd-card" onclick="location.href='#jobs'">
            <h3>💼 人才招聘</h3>
            <p>专业人才供需对接</p>
        </div>
        <div class="kdd-card" onclick="location.href='#second-hand'">
            <h3>🔄 二手产品</h3>
            <p>优质二手设备交易</p>
        </div>
        <div class="kdd-card" onclick="location.href='#solutions'">
            <h3>🧩 应用方案</h3>
            <p>行业解决方案库</p>
        </div>
        <div class="kdd-card" onclick="location.href='#certification'">
            <h3>🏅 资质认证</h3>
            <p>企业资质查询验证</p>
        </div>
    </div>


</template>

<style scoped lang="scss"></style>
